namespace CRM.DataAccess.Entities
{
    using System;
    using System.Collections.Generic;
    using System.ComponentModel.DataAnnotations;
    using System.ComponentModel.DataAnnotations.Schema;
    using System.Data.Entity.Spatial;

    [Table("USERS")]
    public partial class USER
    {
        public long ID { get; set; }

        [StringLength(50)]
        public string SERIAL_NUMBER { get; set; }

        public bool DELETED { get; set; }

        public long? CREATED_BY { get; set; }

        public DateTime DATE_ENTERED { get; set; }

        public long? MODIFIED_USER_ID { get; set; }

        public DateTime DATE_MODIFIED { get; set; }

        [StringLength(100)]
        public string USER_NAME { get; set; }

        [StringLength(100)]
        public string PRIMARY_EMAIL { get; set; }

        [StringLength(150)]
        public string SUR_NAME { get; set; }

        [StringLength(150)]
        public string NAME { get; set; }

        [StringLength(150)]
        public string USER_PASSWORD { get; set; }

        [StringLength(200)]
        public string USER_HASH { get; set; }

        public bool? IS_SUPER_USER { get; set; }

        public bool? ACTIVE { get; set; }

        public bool? IS_ADMIN { get; set; }

        public long? ROLE_ID { get; set; }

        public long? GROUP_ID { get; set; }

        public long? PARENT_GROUP_ID { get; set; }

        public int? DEFAULT_LEAD_VIEW { get; set; }

        [StringLength(150)]
        public string TITLE { get; set; }

        [StringLength(150)]
        public string FAX { get; set; }

        [StringLength(150)]
        public string DEPARTMENT { get; set; }

        [StringLength(100)]
        public string OTHER_EMAIL { get; set; }

        [StringLength(100)]
        public string PHONE_OFFICE { get; set; }

        [StringLength(100)]
        public string SECONDARY_EMAIL { get; set; }

        [StringLength(100)]
        public string PHONE_MOBILE { get; set; }

        public long? REPORTS_TO_ID { get; set; }

        [StringLength(50)]
        public string PHONE_HOME { get; set; }

        [StringLength(50)]
        public string PHONE_SECONDARY { get; set; }

        [StringLength(50)]
        public string CRM_EXTENSION { get; set; }

        [StringLength(150)]
        public string ADDRESS_STREET { get; set; }

        [StringLength(125)]
        public string ADDRESS_COUNTRY { get; set; }

        [StringLength(100)]
        public string ADDRESS_CITY { get; set; }

        [StringLength(20)]
        public string ADDRESS_POSTALCODE { get; set; }

        [StringLength(100)]
        public string ADDRESS_STATE { get; set; }

        public DateTime? PWD_LAST_CHANGED { get; set; }

        [StringLength(60)]
        public string MAIL_SMTPUSER { get; set; }

        [StringLength(200)]
        public string MAIL_SMTPPASS { get; set; }

        public byte[] PICTURE { get; set; }

        public string IMAGE { get; set; }

        public bool? IS_MANAGER { get; set; }
    }
}
